package ebusiness.ebusiness.Dao.OrderDao;

import ebusiness.ebusiness.Entity.Order;
import ebusiness.ebusiness.Entity.OrderDetail;
import org.apache.ibatis.annotations.Param;
import org.aspectj.weaver.ast.Or;

import java.util.Date;
import java.util.List;

public interface OrderInter {
    Order findOrderById(@Param("id") int id);

    List<Order> findOrderByUId(@Param("uid") int uid);
    List<Order> findOrderByDuration(@Param("uid") int uid,@Param("from") String from,@Param("to") String to);
    List<Order> findOrderByDuration2(@Param("from") String from,@Param("to") String to);

    Order findOrder(@Param("id") int id,@Param("uid") int uid);

    List<OrderDetail> findDetailByUID(@Param("uid") int uid);
    List<OrderDetail> findDetailByDuration(@Param("uid") int uid,@Param("from") String from,@Param("to") String to);

    List<OrderDetail> findDetailByID(@Param("id") int id,@Param("uid") int uid);
    List<OrderDetail> findDetailByAdmin(@Param("id") int id);
    List<OrderDetail> findDetailByAdminDuration(@Param("from") String from,@Param("to") String to);
    List<Order> getUnpayOrder(@Param("uid")int uid,@Param("status")String status);

}
